#pragma once
#include "OpenGLPrefix.h"
#ifdef ALICE_OGL
void InitializeOGL();
void CheckLastOpenGLError(const char* file, long line, const char*operation);
#define GLAssert(x) 	{ CheckLastOpenGLError (__FILE__, __LINE__,#x); }
#define OGL_CALL(x) do { x; GLAssert(x); } while(0)

namespace Alice
{
    class CGIOpenGL
    {
    public:
        static GLuint CompileShader(GLenum inShaderType,const char *inShaderCode);
        static GLuint CreateProgram(GLenum* inShaders,size_t inShaderCount);
        static GLuint CreateBufferObject(GLenum inType,const void*inData,int inSize,GLenum inUsage);
        static GLuint CreateFrameBufferObject(GLuint*inColorRTs,GLenum*inColorRTAttachments,int inColorRTCount,GLuint inDSRT);
    };
}
#endif